<?php
/**
 * Redirect Exception
 * HTTP Response exceptions that perform a redirect should extend this class.
 *
 * @package     Visi
 * @subpackage  Exceptions
 * @author      Luke Visinoni <luke.visinoni@gmail.com>
 * @copyright   (c) 2010 Luke Visinoni <luke.visinoni@gmail.com>
 * @version     $Id$
 */
class Visi_Controller_Response_Exception_Redirect extends Visi_Controller_Response_Exception {

    protected $_uri;
    
    public function __construct($message = null, $code = 0, $uri = null) {
    
        $this->setUri($uri);
        return parent::__construct($message, $code);
    
    }
    
    /**
     * Set the URI the resource has been temporarily moved to
     */
    public function setUri($uri) {
    
        $this->_uri = $uri;
        return $this;
    
    }
    
    public function getUri() {
    
        return (string) $this->_uri;
    
    }

}